﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="SearchBookPlan.aspx.cs" Inherits="LandandSurvey.SearchBookPlan" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <h2>
        Welcome to Lands and Surveys Division Plans!
    </h2>
    <hr />
    <p>
        <b>Search Large plans.</b>
    </p>
    <table width="100%">
        <tr>
            <td>Name:</td>
            <td colspan="5"><asp:TextBox Width="100%" ID="txtName" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>Book Number:</td>
            <td><asp:TextBox ID="txtBookNo" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>Folio:</td>
            <td>
                <asp:TextBox ID="txtFolio" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>Acreage:</td>
            <td><asp:TextBox ID="txtAcreage" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>Ward:</td>
            <td>
                <asp:DropDownList ID="ddlWard" runat="server"></asp:DropDownList></td>
        </tr>
        <tr>
            <td>Ward Ref - Cassini:</td>
            <td><asp:TextBox ID="txtWardRefCassini" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>Ward Ref - UTM:</td>
            <td><asp:TextBox ID="txtWardRefUTM" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>Surveyor:</td>
            <td>
                <asp:DropDownList ID="ddlSurveyor" runat="server"></asp:DropDownList></td>
            <td>&nbsp</td>
            <td>Date Signed - Surveyor:</td>
            <td><asp:TextBox ID="txtDateSignedSurveyor" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>Date Signed - Director:</td>
            <td><asp:TextBox ID="txtDateSignedDirector" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>Survey Order Number:</td>
            <td><asp:TextBox ID="txtSurveoyOrderNo" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>RPO - Volume:</td>
            <td><asp:TextBox ID="txtRPOVolume" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>RPO - Folio:</td>
            <td><asp:TextBox ID="txtRPOFolio" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>CT - Volume:</td>
            <td><asp:TextBox ID="txtCTVolume" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>CT - Folio:</td>
            <td><asp:TextBox ID="txtCTFolio" runat="server"></asp:TextBox></td>
        </tr>
        <tr valign="top">
            <td>L&S Number:</td>
            <td><asp:TextBox ID="txtLSNumber" runat="server"></asp:TextBox></td>
            <td>&nbsp</td>
            <td>Deed Number:</td>
            <td><asp:TextBox ID="txtDeedNumber" runat="server"></asp:TextBox></td>
        </tr>
        <tr>
            <td>&nbsp</td>
            <td><asp:Button ID="btnSearch" runat="server" Text="Search Plan" OnClick="btnSearch_Click" /></td>
            <td>&nbsp;</td>
        </tr>
    </table>
    <br />
    <h3>Results</h3>
    <hr />
    <div>
        <asp:GridView ID="gvResults" runat="server" AutoGenerateColumns="False" BackColor="White"
            BorderColor="#999999" BorderStyle="None" BorderWidth="1px" CellPadding="3" GridLines="Vertical">
            <AlternatingRowStyle BackColor="#DCDCDC" />
            <Columns>
                <asp:HyperLinkField DataNavigateUrlFields="Id" DataNavigateUrlFormatString="~/EditBookPlan.aspx?id={0}" Text="View" />
                
                <asp:TemplateField HeaderText="Name">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblOwner"><%# DataBinder.Eval( Container.DataItem, "Name" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Book No">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblBookNo"><%# DataBinder.Eval( Container.DataItem, "BookNo" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Folio">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblFolio"><%# DataBinder.Eval( Container.DataItem, "Folio" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Acreage">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblLocation"><%# DataBinder.Eval( Container.DataItem, "Acreage" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Ward">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblAcreage"><%# DataBinder.Eval( Container.DataItem, "Ward" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Survey Order Number">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblDateSigned"><%# DataBinder.Eval( Container.DataItem, "SurveyOrderNumber" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="RPO - Volume">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblDateSigned"><%# DataBinder.Eval( Container.DataItem, "RPOVolume" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="RPO - Folio">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblDateSigned"><%# DataBinder.Eval( Container.DataItem, "RPOFolio" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="CT - Volume">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblDateSigned"><%# DataBinder.Eval( Container.DataItem, "CTVolume" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="CT - Folio">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblDateSigned"><%# DataBinder.Eval( Container.DataItem, "CTFolio" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="L&S Number">
                    <ItemTemplate>
                        <asp:Label runat="server" ID="lblDateSigned"><%# DataBinder.Eval( Container.DataItem, "LandSNumber" )%></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
            <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
            <HeaderStyle BackColor="#000084" Font-Bold="True" ForeColor="White" />
            <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
            <RowStyle BackColor="#EEEEEE" ForeColor="Black" />
            <SelectedRowStyle BackColor="#008A8C" Font-Bold="True" ForeColor="White" />
            <SortedAscendingCellStyle BackColor="#F1F1F1" />
            <SortedAscendingHeaderStyle BackColor="#0000A9" />
            <SortedDescendingCellStyle BackColor="#CAC9C9" />
            <SortedDescendingHeaderStyle BackColor="#000065" />
            <EmptyDataTemplate>
                <span>No records found.</span>
            </EmptyDataTemplate>
        </asp:GridView>
    </div>
</asp:Content>
